function edit_person(displayDiv, editDiv, form_id) {
	var name = document.getElementById(form_id).name.value;
	var username = document.getElementById(form_id).username.value;
	var email = document.getElementById(form_id).email.value;
	var id = document.getElementById(form_id).personid.value;
	
	var url = "/people/edit_person?name=" + name;
	url += "&username=" + username;
	url += "&email=" + email;
	url += "&personid=" + id;
	
	
	function show_edit_info(result) {
		var person = result['person'];
		
		var yourname = document.getElementById('person_name_'+ person.id);
		var yourid = document.getElementById('person_id_' + person.id);
		var youremail = document.getElementById('person_email_' + person.id);
		var personname = document.getElementById('person_h3_' + person.id);
		
		yourname.innerHTML = person.displayName;
		yourid.innerHTML = person.userId;
		youremail.innerHTML = person.emailAddress;	
		personname.innerHTML = person.displayName;
	}
	
	var d = loadJSONDoc(url);
	d.addCallback(show_edit_info);
}

function edit_password(displayDiv, editDiv, form_id) {
	var password = document.getElementById(form_id).password.value;
	var confirm = document.getElementById(form_id).confirm.value;
	var id = document.getElementById(form_id).personid.value;
	
	var url = "/people/edit_password?password=" + password;
	url += "&confirm=" + confirm;
	url += "&personid=" + id;
	
	function show_password_info(result) {
		
	}
	
	var d = loadJSONDoc(url);
	d.addCallback(show_password_info);
}	